/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package fr.istia.gesstages.jpa;

import java.io.Serializable;
import java.util.Date;
import javax.persistence.*;

/**
 *
 * @author Cédric Moreau
 */
@Entity
@Table(name = "offres")
public class Offer implements Serializable {

    public Offer() {
    }

    public Offer(String enonce, String titre, String entreprise, String adresse, String codePostal, String ville, Date dateOffre, Date dateEnvoi, Boolean visible, Boolean istia, String owner, String file, String promo, String nom, String prenom, String maitre, Boolean archive) {
        this.enonce = enonce;
        this.titre = titre;
        this.entreprise = entreprise;
        this.adresse = adresse;
        this.codePostal = codePostal;
        this.ville = ville;
        this.dateOffre = dateOffre;
        this.dateEnvoi = dateEnvoi;
        this.visible = visible;
        this.istia = istia;
        this.owner = owner;
        this.file = file;
        this.promo = promo;
        this.nom = nom;
        this.prenom = prenom;
        this.maitre = maitre;
        this.archive = archive;
    }

    @Id
    @Column(name = "st_id", nullable = false)
    @GeneratedValue(strategy = GenerationType.AUTO)
    private Integer id;
    @Column(name = "st_version", nullable = false)
    private int version;
    @Column(name = "st_enonce", nullable = false, length = 9000)
    private String enonce;
    @Column(name = "st_titre", nullable = false, length = 255)
    private String titre;
    @Column(name = "st_entreprise", nullable = false, length = 255)
    private String entreprise;
    @Column(name = "st_adresse", nullable = false)
    private String adresse;
    @Column(name = "st_codepostal", nullable = false, length = 5)
    private String codePostal;
    @Column(name = "st_ville", nullable = false)
    private String ville;
    @Column(name = "st_dateoffre", nullable = false)
    @Temporal(TemporalType.DATE)
    private Date dateOffre;
    @Column(name = "st_dateenvoi", nullable = false)
    @Temporal(TemporalType.DATE)
    private Date dateEnvoi;
    @Column(name = "st_visible", nullable = false)
    private Boolean visible;
    @Column(name = "st_istia", nullable = false)
    private Boolean istia;
    @Column(name = "st_owner", nullable = false)
    private String owner;
    @Column(name = "st_file", nullable = false)
    private String file;
    @Column(name = "st_promo", nullable = false, length = 4)
    private String promo;
    @Column(name = "st_nom", nullable = false)
    private String nom;
    @Column(name = "st_prenom", nullable = false)
    private String prenom;
    @Column(name = "st_maitre", nullable = false)
    private String maitre;
    @Column(name = "st_archive", nullable = false)
    private Boolean archive;

    /**
     * @return the id
     */
    public Integer getId() {
        return id;
    }

    /**
     * @param id the id to set
     */
    public void setId(Integer id) {
        this.id = id;
    }

    /**
     * @return the version
     */
    public int getVersion() {
        return version;
    }

    /**
     * @param version the version to set
     */
    public void setVersion(int version) {
        this.version = version;
    }

    /**
     * @return the enonce
     */
    public String getEnonce() {
        return enonce;
    }

    /**
     * @param enonce the enonce to set
     */
    public void setEnonce(String enonce) {
        this.enonce = enonce;
    }

    /**
     * @return the titre
     */
    public String getTitre() {
        return titre;
    }

    /**
     * @param titre the titre to set
     */
    public void setTitre(String titre) {
        this.titre = titre;
    }

    /**
     * @return the entreprise
     */
    public String getEntreprise() {
        return entreprise;
    }

    /**
     * @param entreprise the entreprise to set
     */
    public void setEntreprise(String entreprise) {
        this.entreprise = entreprise;
    }

    /**
     * @return the adresse
     */
    public String getAdresse() {
        return adresse;
    }

    /**
     * @param adresse the adresse to set
     */
    public void setAdresse(String adresse) {
        this.adresse = adresse;
    }

    /**
     * @return the codePostal
     */
    public String getCodePostal() {
        return codePostal;
    }

    /**
     * @param codePostal the codePostal to set
     */
    public void setCodePostal(String codePostal) {
        this.codePostal = codePostal;
    }

    /**
     * @return the ville
     */
    public String getVille() {
        return ville;
    }

    /**
     * @param ville the ville to set
     */
    public void setVille(String ville) {
        this.ville = ville;
    }

    /**
     * @return the dateOffre
     */
    public Date getDateOffre() {
        return dateOffre;
    }

    /**
     * @param dateOffre the dateOffre to set
     */
    public void setDateOffre(Date dateOffre) {
        this.dateOffre = dateOffre;
    }

    /**
     * @return the dateEnvoi
     */
    public Date getDateEnvoi() {
        return dateEnvoi;
    }

    /**
     * @param dateEnvoi the dateEnvoi to set
     */
    public void setDateEnvoi(Date dateEnvoi) {
        this.dateEnvoi = dateEnvoi;
    }

    /**
     * @return the owner
     */
    public String getOwner() {
        return owner;
    }

    /**
     * @param owner the owner to set
     */
    public void setOwner(String owner) {
        this.owner = owner;
    }

    /**
     * @return the file
     */
    public String getFile() {
        return file;
    }

    /**
     * @param file the file to set
     */
    public void setFile(String file) {
        this.file = file;
    }

    /**
     * @return the promo
     */
    public String getPromo() {
        return promo;
    }

    /**
     * @param promo the promo to set
     */
    public void setPromo(String promo) {
        this.promo = promo;
    }

    /**
     * @return the nom
     */
    public String getNom() {
        return nom;
    }

    /**
     * @param nom the nom to set
     */
    public void setNom(String nom) {
        this.nom = nom;
    }

    /**
     * @return the prenom
     */
    public String getPrenom() {
        return prenom;
    }

    /**
     * @param prenom the prenom to set
     */
    public void setPrenom(String prenom) {
        this.prenom = prenom;
    }

    /**
     * @return the maitre
     */
    public String getMaitre() {
        return maitre;
    }

    /**
     * @param maitre the maitre to set
     */
    public void setMaitre(String maitre) {
        this.maitre = maitre;
    }

    public Boolean getVisible() {
        return visible;
    }

    public void setVisible(Boolean visible) {
        this.visible = visible;
    }

    public Boolean getIstia() {
        return istia;
    }

    public void setIstia(Boolean istia) {
        this.istia = istia;
    }

    public Boolean getArchive() {
        return archive;
    }

    public void setArchive(Boolean archive) {
        this.archive = archive;
    }
}
